package org.cainiao.basic.collection;

import org.cainiao.util.Util;

import java.util.Iterator;
import java.util.LinkedHashSet;
import java.util.TreeSet;

/**
 * <br />
 * <p>
 * Author: Cai Niao(wdhlzd@163.com)<br />
 */
public class SetTest {

    public static void main(String[] args) {
        TreeSet<String> treeSet = new TreeSet<>();
        test();
    }

    private static void test() {
        LinkedHashSet<String> linkedHashSet = new LinkedHashSet<>();
        linkedHashSet.add("a");
        linkedHashSet.add("b");
        linkedHashSet.add("c");
        Iterator<String> iterator = linkedHashSet.iterator();
        for (String s : linkedHashSet) {
            Util.log("LinkedHashSet >>> ", s);
        }
    }
}
